package com.itheima.controller;

import com.itheima.entity.Result;
import com.itheima.service.OrderService;
import org.apache.dubbo.config.annotation.Reference;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

@RestController
@RequestMapping("/eduorder/paylog")
@CrossOrigin
public class PayLogController {
    @Reference
    private OrderService orderService;


    @GetMapping("createNative/{orderNo}")
    public Result createNative (@PathVariable("orderNo") Integer orderId ){
     Map map = orderService.createNatvie(orderId);
        System.out.println("****返回的二维码的map集合是:*****"+map);
        return  new Result(true,"返回支付的微信二维码",map);
    }
}
